
var findLengthOfLCIS = function (nums) {
    var findLCIS = function (nums,begin) {
        let len=nums.length
        for (let i = begin; i < len-1; i++) {
            /* console.log(nums[i],nums[i+1]); */
            if (nums[i] >= nums[i + 1]) {
                return i
            }
            
        }
        return len-1
       
    }
    let len = nums.length
    if(len===1){
        return 1
    }
    let max = -1
    
    var count=0
   
    while (0<=count<=len-1) {
        /* console.log("count:",count); */
        
        let end=findLCIS(nums,count)
        /* console.log(count,end); */
        /* console.log('end:',end); */
        if(end-count+1>=max){
            max=end-count+1
            
            
        }
        console.log(count,end,max);
        count=end+1
        if(count>len-1){
            break;
        }
       
    }
    return max
}
var nums = [1, 3]
console.log(findLengthOfLCIS(nums,0));